home *** CD-ROM | disk | FTP | other *** search
/ Almathera Ten Pack 3: CDPD 3 / Almathera Ten on Ten - Disc 3: CDPD3.iso / scope / 001-025 / scopedisk7 / rxutil / touch.rexx < prev    next >
OS/2 REXX Batch file  |  1995-03-18  |  361b  |  16 lines

  1. /* touch -- set the date or time of a file. Calls setdate. If the file does
  2.             not exist, creates it as an empty file */
  3. parse arg x
  4. if index(x,'*') >0 | index(x,'#?') >0 | index(x,'?') >0 | index(x,'|') >0 then
  5.  do
  6.  setdate x
  7.  end
  8. else
  9.  if exists(word(x,1)) then setdate x
  10. else
  11.  do
  12.  scratch = open(dummy,x,'w')
  13.  scratch = close(dummy)
  14.  setdate x
  15.  end
  16.